//
//  ProgressView.h
//  Untitled
//
//  Created by  user on 11-4-29.
//  Copyright 2011 GuangZhouXuanWu. All rights reserved.
//

#import <UIKit/UIKit.h>

@class CProgressView;

@class CProgressViewPanel;

@protocol CProgressViewPanelDelegate

-(void)touchProgressViewPanel:(CProgressViewPanel*)pvp;

-(UIView*)getProgressViewPanelParent:(CProgressViewPanel*)pvp;

-(CGRect)getProgressViewPanelCoverRect:(CProgressViewPanel*)pvp;

-(void)progressViewPanelDidRemove:(CProgressViewPanel*)pvp;

-(CGPoint)getProgressViewCenterPosition:(CProgressViewPanel*)pvp;

//-(void)PregressViewPanelDelegateDidExchange;

@end

@interface CProgressViewPanel : UIView
{
	CProgressView* _progressView;
	NSInteger _nCount;
	__unsafe_unretained id<CProgressViewPanelDelegate> _delegate;
}

@property(nonatomic,weak) CProgressView* progressView;
@property(nonatomic,assign) NSInteger nCount;
@property(nonatomic,retain) id<CProgressViewPanelDelegate> delegate;

@end

@interface CProgressViewPanelHelper: NSObject
{
	CProgressViewPanel* _pvpanel;
    NSTimeInterval _delayReleaseTime;
	NSLock* _pvplock;
	
}

@property(nonatomic,readonly) CProgressViewPanel* pvpanel;
@property(nonatomic,assign) NSTimeInterval delayReleaseTime;

-(void)progressViewPanelHelperWithActivity:(BOOL)bActivity title:(NSString*)szTitle text:(NSString*)szText delegate:(id<CProgressViewPanelDelegate>)delegate;

-(void)retainProgressViewPanel;

-(void)releaseProgressViewPanel;

-(void)forceReleaseProgressViewPanel;

-(void)setText:(NSString*)szText;

+(void)setBlurBackground:(BOOL)blurBackground;

@end
